package com.baidu.dtx.score.controller;

import com.baidu.dtx.score.dto.ScoreDTO;
import com.baidu.dtx.score.service.ScoreService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author shilei
 * @create 2021-06-07 15:46
 */
@RestController
@Slf4j
public class ScoreController
{
    @Resource
    private ScoreService scoreService;

    @RequestMapping("/score/decrease")
    public String  decrease(@RequestBody ScoreDTO scoreDTO) {
        log.info("------进入积分controller");
        this.scoreService.decrease(scoreDTO);
        return  "ok";
    }
}


